<?php
	session_start();
	
?>
<!DOCTYPE html>
<html>
<head>
	<title>用户登录</title>
	<meta charset="utf-8">
	<style type="text/css">
		*{
			margin: 0;
			padding: 0;
		}
		body{
			background-image: url('img/back.jpg');
			background-size: 100% 100%;
		}
		.all{
			width: 100%;
			height: 100%;
			line-height: 100%;
		}
		.login{
			width: 470px;
			height: 330px;
			margin:100px auto;
			border:3px #222222 solid;
			border-radius: 6px;
			box-shadow: 15px 15px 5px lightgrey;
		}
		.login_inner{
			width:400px;
			margin: 20px;

		}
		.bg_top{
			background-color: #222222;
			color: white;
			height: 35px;
			line-height: 35px;
			font-size: 22px;
		}
		.captach{	
			display: inline-block;
			text-decoration: none;
			color: black;
			font-size: 12px;
			vertical-align: bottom;
		}
		input{
			width: 150px;
			height: 30px;
			line-height: 30px;
			font-size: 16px;
			border-radius: 5px;
			box-shadow: 10px;
			background-color: lightgrey;
		}
		.check_login_auto{
			width: 80px;
			height: 13px;
		}
		.but{
			width: 80px;
			height: 40px;
			line-height: 40px;
			border-radius: 5px;
			box-shadow: 5px 5px 5px grey;
			background-color: #222222;
			color: #fff;
		}
	</style>
</head>
<body>
<div class="all">
	<div><a href="register.php">用户注册</a></div>
	<div><a href="../article/index.php">路过而已</a></div>
	<div class="login">
		<div class="bg_top">　　登录首页</div>
		<div class="login_inner">
			<form action="act.php" method="post">

				<label>
					用户名：<input type="text" name="user"><?php if(isset($_SESSION['num'])&&($_SESSION['num']=='103'||$_SESSION['num']=='105')&&isset($_SESSION['error'])){echo $_SESSION['error'];}?><br><br>
				</label>
				<label>
					密　码：<input type="password" name="pass"><?php if(isset($_SESSION['num'])&&($_SESSION['num']=='104'||$_SESSION['num']=='106')&&isset($_SESSION['error'])){echo $_SESSION['error'];}?><br><br>
				</label>
				<label>
					验证码：<input type="text" name="cap">
				</label>
				<?php if(isset($_SESSION['num'])&&($_SESSION['num']=='101'||$_SESSION['num']=='102')&&isset($_SESSION['error'])){echo $_SESSION['error'];}?>
				<a href="login.php" class="captach"><img src="captach.php">&nbsp;点击刷新</a><br><br>
				<label><input type="checkbox" name="login_auto" value="1" class="check_login_auto"><a class="captach">十天之内免登录</a></label><br><br>
				　　　　<input type="submit"　name="sub" value="登录"  class="but">　　　<input type="reset" name="res"  class="but">
			</form>
		</div>
	</div>
</div>
</body>
</html>